Instead of duplicating this code in multiple places,
add an api to look up an action group for a prefixed
name, and return the unprefixed name at the same time.
return group;
}
+GActionGroup *
+gtk_action_muxer_find (GtkActionMuxer *muxer,
+ const char *action_name,
+ const char **unprefixed_name)
+{
+ Group *group;
+
+ group = gtk_action_muxer_find_group (muxer, action_name, unprefixed_name);
+
+ return group->group;
+}
+
static void
gtk_action_muxer_action_enabled_changed (GtkActionMuxer *muxer,
const gchar *action_name,
return action_and_target;
}
+
const gchar ** gtk_action_muxer_list_prefixes (GtkActionMuxer *muxer);
GActionGroup * gtk_action_muxer_lookup (GtkActionMuxer *muxer,
const gchar *prefix);
+GActionGroup * gtk_action_muxer_find (GtkActionMuxer *muxer,
+ const char *action_name,
+ const char **unprefixed_name);
GtkActionMuxer * gtk_action_muxer_get_parent (GtkActionMuxer *muxer);
void gtk_action_muxer_set_parent (GtkActionMuxer *muxer,